package com.foreknow.demo4;

public class Manager {
    public static void main(String[] args) {
        //登录(根据用户名密码)
        boolean isRight =  Manager.usrLogin("test","123456");
        if (isRight){
            System.out.println("登录成功");
        }else {
            System.out.println("登录失败");
        }
        //注册(填写用户名和密码)

        //根据id查询用户名
        String userName = Manager.getUser(1);
        if (userName != null){
            System.out.println("");
        }else {
            System.out.println("该用户不存在");
        }
        //根据id删除用户

        //修改用户信息(修改用户名和密码)
    }

    public static boolean usrLogin(String username,String pwd){
        //select * form user where id =? and password = ?
        return true;
    }
    public static boolean usrRegister(String username,String pwd){
        //insert into user(username,password) values("tom","123456");
        return true;
    }
    public static String getUser(int id){
        //select username from user where id = ?
        String userName = "";
        return  userName;
    }
    public static void delUser(String id){

    }
    public static void alterUser(String id){

    }
}
